package com.gton.usermanage.controller;


import com.gton.annotation.SwaggerScanClass;
import com.gton.io.Resp;
import com.gton.usermanage.entity.GatewayRutor;
import com.gton.usermanage.service.GatewayRutorService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author GuoTong
 * @since 2022-10-22
 */
@RestController
@RequestMapping("/gatewayRutor")
@Api(tags = "网关配置")
@SwaggerScanClass
public class GatewayRutorController {

    @Autowired
    private GatewayRutorService gatewayRutorService;

    @GetMapping("/getList")
    public Resp<List<GatewayRutor>> getList() {
        Resp<List<GatewayRutor>> listResp = Resp.Ok();
        List<GatewayRutor> list = gatewayRutorService.list();
        listResp.setData(list);
        return listResp;
    }

}

